package com.tina;

import com.tina.util.DockerUtil;
import com.tina.util.XshellUtil;

/**
 * @author Tina
 * @version 1.0
 * @since 2021/11/17 16:03
 **/
public class Xshell {


    public static void main(String[] args) {
//        StringBuilder dockerfile = createDockerfile();
//        System.out.println(dockerfile);
//        System.out.println("------------------------------------------------------------------------------------");
//        String buildCmd = buildCmd("springboot-build-test");
//        StringBuilder buildResult = sh(buildCmd);
//        System.out.println(buildResult);
//        System.out.println("------------------------------------------------------------------------------------");
//
//        String runCmd = runCmd("springboot-build-test-58080", "springboot-build-test", 58080, 8080, "/Users/tina/IdeaProjects/tinaspringboot/hangingDirectory", 1, 500);
//        System.out.println(runCmd);
//        System.out.println("------------------------------------------------------------------------------------");
//        StringBuilder runResult = sh(runCmd);
//        System.out.println(runResult);

//        String cmd = deleteInstCmd("springboot-build-test-58080");
        String deleteImagesCmd = DockerUtil.stats("7b805a86d2ee 83624fbaa886");
//        System.out.println(sh(stopcmd));
        System.out.println(deleteImagesCmd);
        StringBuilder sh = XshellUtil.sh(deleteImagesCmd);
        System.out.println(sh);


    }

}
